﻿namespace Away.IdentityServer.Core.Services.Impl;

[ServiceInject(ServiceLifetime.Scoped)]
public class ApiResourceService : IApiResourceService
{
    private readonly IApiResourceRepository _apiResourceRepository;
    public ApiResourceService(IApiResourceRepository apiResourceRepository)
    {
        _apiResourceRepository = apiResourceRepository;
    }

    public IResult Page(ApiResourceSearch search)
    {
        return _apiResourceRepository.Page(search);
    }

    public void Remove(List<int> ids)
    {
        _apiResourceRepository.Remove(ids);
    }

    public void Save(ApiResource model)
    {
        _apiResourceRepository.Save(model);
    }
}
